{% extends "base.html" %}

{% block body %}
  <div>检查结果：</div>
  {% if history %}
    您于 {{history.gmtCreate|date:"Y-m-d H:i:s"}} 备份网站 {{history.site|urlize}}, 总大小为{{history.pageSize|add:history.imageSize|filesizeformat}}
    <br/>共抓取{{history.pageCount}}个页面,大小为{{history.pageSize|filesizeformat}}
    <br/>共抓取{{history.imageCount}}张图片,大小为{{ history.imageSize|filesizeformat }}
  {% endif %}
  <br/><a href="/">返回继续检查</a>

  {% if pages %}
    页面:
    <table width="100%" border="1">
        <tr>
            <td align="center">URL</td>
            <td align="center">时间</td>
            <td align="center">大小</td>
        </tr>
      {% for page in pages %}
        <tr>
            <td><a href="/showpage?key={{page.key}}" target="_blank">{{page.sourceUrl}}</a></td>
            <td align="center">{{page.gmtCreate|date:"Y-m-d H:i:s"}}</td>
            <td align="right">{{ page.size|filesizeformat }}</td>
        </tr>
      {% endfor %}
    </table>
  {% endif %}
  
  {% if images %}
    图片:
    <table width="100%" border="1">
        <tr>
            <td align="center">名称</td>
            <td align="center">图片</td>
            <td align="center">大小</td>
        </tr>
      {% for image in images %}
        <tr>
            <td><a href="{{image.url}}" target="_blank">{{image.title}}</a></td>
            <td align="center"><img src="/showimage?key={{image.key}}"/></td>
            <td align="right">{{ image.size|filesizeformat }}</td>
        </tr>
      {% endfor %}
    </table>
  {% endif %}
  
{% endblock %}